﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;

public partial class _Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (Session["user"] != null)
        {
            this.Log_in1.Visible = false;
            this.Log_out1.Visible = true;
        }
        else
        {
            this.Log_in1.Visible = true;
            this.Log_out1.Visible = false;
        }
        //if (this.Request.Params.Get("uid") != null)
        //{
        //    if (Session["user"] != null)
        //    {
        //        this.Log_in1.Visible = false;
        //        this.Log_out1.Visible = true;
        //    }
        //    else
        //    {
        //        //Response.Redirect("default.aspx");
        //    }
        //}
        //else
        //{
        //    if (Session["user"] != null)
        //    {
        //        this.Log_in1.Visible = false;
        //        this.Log_out1.Visible = true;
        //    }
        //    else
        //    {
        //        this.Log_in1.Visible = true;
        //        this.Log_out1.Visible = false;
        //    }
        //}
        if (!Page.IsPostBack)
        {
            if (Session["user"] != null)
            {
                this.Log_in1.Visible = false;
                this.Log_out1.Visible = true;
            }
            else
            {
                this.Log_in1.Visible = true;
                this.Log_out1.Visible = false;
            }
        }
        else
        {
        }
    }
}
